package diva.pap.affiliate;

import android.os.Bundle;
import diva.android_library.view.TabActivityBase;
import diva.pap.R;
import diva.pap.SettingsActivity;
import diva.pap.TraficActivity;

public class AffiliateActivity extends TabActivityBase {
  private final AffiliateSellNotificationPresenter sellNotifications =
      new AffiliateSellNotificationPresenter(this);

  @Override
  public void onCreate(Bundle state) {
    super.onCreate(state);
    setContentView(R.layout.tabview);
    // getTabHost().getTabWidget().setDividerDrawable(R.drawable.tab_divider2);
    addTab(TraficActivity.class, "trafic", new PapTabView(this, R.string.traffic_tab_label,
        R.drawable.tab_traffic));
    addTab(AffiliateTransactionsActivity.class, "affiliate_transactions", new PapTabView(this,
        R.string.transactions_tab_label, R.drawable.tab_transactions));
    addTab(SettingsActivity.class, "settings", new PapTabView(this, R.string.settings_tab_label,
        R.drawable.tab_settings));
    getTabHost().setCurrentTab(0);
    sellNotifications.onCreate();
  }

  @Override
  protected void onDestroy() {
    super.onDestroy();
    sellNotifications.onDestroy();
  }
}
